const { defineConfig } = require('@vue/cli-service');

module.exports = defineConfig({
  transpileDependencies: true,
  devServer: {
    proxy: {
      '/image': {
        target: 'file:///D:/vue-program/driving-school/driving/public/image',
        changeOrigin: true,
        secure: false,
        pathRewrite: {
          '^/image': ''
        }
      }
    }
  },
  configureWebpack: {
    resolve: {
      fallback: {
        // 将 'util/' 修改为 'util'
        util: require.resolve('util'),
      },
    },
  },
});